<!DOCTYPE html>
<html lang="zh">
<head>
  <meta charset="UTF-8">
  <title>{{pageTitle}}</title>
  <link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@3.3.7/dist/css/bootstrap.min.css" integrity="sha384-BVYiiSIFeK1dGmJRAkycuHAHRg32OmUcww7on3RYdg4Va+PmSTsz/K68vbdEjh4u" crossorigin="anonymous">
  <script src="https://cdn.jsdelivr.net/npm/jquery@1.12.4/dist/jquery.min.js"></script>
  <style>
    header{padding: 70px 0 70px 0;background-color: #4A6495; margin-bottom: 20px;}
    h1{font-size: 36px;color:#fff;font-weight: normal;} 
  </style>
  <script>
    $(function() {
      $('#btn').click(function() {
        var url = $('[name=url]').val();
        var reg = /^https?:\/\/\w+\.\w+/;
        $.ajax({
          url: '/index/update',
          type: 'post',
          dataType: 'json',
          data: {url: url},
          success: function(res) {
            console.log(res);
          }
        })
      });
    });
  </script>
</head>
<body>
  <header>
    <div class="wrap container">
      <h1>{{title}}</h1>
    </div>
  </header>
  <div class="container">
    <div class="row">
      <div class="col-md-10">
        <input type="text" class="form-control" name="url" value="https://ncov.dxy.cn/ncovh5/view/pneumonia" placeholder="请输入URL">
      </div>
      <div class="col-md-2"><button type="button" id="btn" class="btn btn-block btn-primary">开始</button></div>
    </div>
    
    
  </div>
</body>
</html>
